<template>
  <div class="">
    token: {{ token }}
    <van-button @click="setToken">设置token</van-button>
  </div>
</template>

<script setup>
import { computed } from '@vue/reactivity';
import { useStore } from 'vuex';

const store = useStore()
const setToken = () => {
  store.commit('set_token', 11111111111111111111)
}

const token = computed(() => store.state.common.token)
</script>

<style lang="scss" scoped></style>
